<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="ThemeBucket">
    <link rel="shortcut icon" href="#" type="image/png">

    <title>Login</title>

    <link href="/static/css/style.css" rel="stylesheet">
    <link href="/static/css/style-responsive.css" rel="stylesheet">

    <script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/semantic-ui@2.4.2/dist/components/form.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/semantic-ui@2.4.2/dist/components/transition.js"></script>

    <script type="text/javascript" src="/static/scripts/base.js"></script> <!-- 引入项目的访问路径 -->
    <script type="text/javascript" src="/static/scripts/cookie.js"></script><!-- 引入cookie -->
    <script type="text/javascript" src="/static/scripts/login.js"></script><!-- 引入登录和注册的处理 -->
</head>

<body class="login-body">

<div class="container">

<!--    <form class="form-signin" action="edit.html" >-->
    <form class="form-signin"  onsubmit="return false">
        <div class="form-signin-heading text-center">
            <h1 class="sign-title">Sign In</h1>
            <img src="/static/images/login-logo.png" alt=""/>
        </div>
        <div class="login-wrap">
            <input type="text" class="form-control" id="username"  placeholder="请输入用户名" autofocus>
            <input type="password" class="form-control" id="password" placeholder="请输入密码">
            <div class='warning' id='warning_1'><span></span></div>
            <button id="login"class="btn btn-lg btn-login btn-block" type="submit">
                <i class="fa fa-check"></i>
            </button>

            <div class="registration">
                没有账号
                <a class="" href="registration.html">
                    注册
                </a>
            </div>
            <label class="checkbox">
                <input type="checkbox" value="remember-me"> 记住我
                <span class="pull-right">
                    <a data-toggle="modal" href="#myModal"> 忘记密码？</a>

                </span>
            </label>

        </div>

        <!-- Modal -->
        <div aria-hidden="true" aria-labelledby="myModalLabel" role="dialog" tabindex="-1" id="myModal" class="modal fade">
            <div class="modal-dialog">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                        <h4 class="modal-title">Forgot Password ?</h4>
                    </div>
                    <div class="modal-body">
                        <p>Enter your e-mail address below to reset your password.</p>
                        <input type="text" name="email" placeholder="Email" autocomplete="off" class="form-control placeholder-no-fix">

                    </div>
                    <div class="modal-footer">
                        <button data-dismiss="modal" class="btn btn-default" type="button">Cancel</button>
                        <button class="btn btn-primary" type="button">Submit</button>
                    </div>
                </div>
            </div>
        </div>
        <!-- modal -->

    </form>

</div>

<!-- Placed js at the end of the document so the pages load faster -->
<script src="/static/js/jquery-1.10.2.min.js"></script>
<script src="/static/js/bootstrap.min.js"></script>
<script src="/static/js/modernizr.min.js"></script>
<!--<script type="text/javascript" charset="UTF-8">
    // 登录账号
     $("#login").click(function(){
         login();
     });
     $("#login").on("click", function () {
         $.ajax({
             url: "login.do",
             type: "POST",
             data: {
                 username: $("#username").val(),
                 password: $("#password").val()
             },
             resultType: "JSON",
             success: function (result) {
                  alert(result.message);
                 if (result.status==0) {
                     //登陆成功，进入系统
                     window.location.href="edit.html";
                     addCookie("cnUserId",result.data.user.cnUserId,5);
                     addCookie("cnUserName",result.data.user.cnUserName,5);

                 }
             },
             error: function (result) {
                 alert("请求失败.");
             }
         });
     });
</script>-->
</body>
</html>